package so.sao.code.service.infrastructure.jpa.convert;

import javax.persistence.AttributeConverter;

import so.sao.code.service.infrastructure.enums.PrintFileFormatStatus;

public class PrintFileFormatStatusConvert implements AttributeConverter<PrintFileFormatStatus, Integer> {

	@Override
	public Integer convertToDatabaseColumn(PrintFileFormatStatus attribute) {
		return attribute.getValue();
	}

	@Override
	public PrintFileFormatStatus convertToEntityAttribute(Integer dbData) {
		return PrintFileFormatStatus.fromValue(dbData);
	}

}
